<label class="caption1">
    修改线路
</label>
<br/>
<br/>
<div class="edit_form">
    <%= error_messages_for :tour %>
    <% form_for([:admin, @tour], :html=>{:multipart => true}) do |f| %>
    <p>
        <label for="tour_tour_category">
            所属分类
        </label>
        <br/>
        <%= collection_select("tour", "tour_category_id" , TourCategory.find(:all), "id", "name") %>
    </p>
    <p>
        <b>线路名称</b>
        <br/>
        <%= f.text_field :name %>
    </p>
	<p>
        <label for="picture">
            图片
        </label>
		<br/>
		<%= image_tag url_for(:controller => "/admin/attachments", :action => "render_attachment", :id => @tour.picture), :size=>"160x120"%>
        <br/>
		<%= file_field_tag "picture" %>
    </p>
	<p>
        <label for="tour_summary">
            线路简介
        </label>
        <br/>
        <%= fckeditor_textarea("tour", "summary", :toolbarSet => 'Simple', :width => '100%', :height => '200px') %>
    </p>
    <p>
        <label for="tour_description">
            线路描述
        </label>
        <br/>
        <%= fckeditor_textarea("tour", "description", :toolbarSet => 'Simple', :width => '100%', :height => '400px') %>
    </p>
    <%= f.submit "保存", :class=>"submit" %>
    <%= render :partial => "admin/destroy_link", :locals =>{:url => [:admin, @tour], :name => "线路“#{@tour.name}”"} %>
    |<%= link_to '取消', admin_tours_path %>
    <% end %>
</div>
